package sv.gob.mh.dgii.model.custom.constraints;

import static java.lang.annotation.ElementType.*;
import static java.lang.annotation.RetentionPolicy.*;
import java.lang.annotation.Documented;
import java.lang.annotation.Retention;
import java.lang.annotation.Target;
import javax.validation.Constraint;
import javax.validation.Payload;
import sv.gob.mh.dgii.model.validators.IfValidator;

@Target( { TYPE, ANNOTATION_TYPE })
@Retention(RUNTIME)
@Constraint(validatedBy = IfValidator.class)
@Documented
public @interface ValidateIf {

    String message() default "{sv.gob.mh.dgii.constraints.if}";

    Class<?>[] groups() default {};

    Class<? extends Payload>[] payload() default {};
    
    String metodo() default "";
    String propiedad() default "";
}
